﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;


/** ** ** ** ** ** ** ** ** ** ** ** ** ** ** ** ** ** ** **
 * Description: 
 * Author: Heller (HellerSong@outlook.com)
 * CreationTime: 3/4/2015 2:23:54 PM
 ** ** ** ** ** ** ** ** ** ** ** ** ** ** ** ** ** ** ** **/
namespace DevGrammar.Pattern
{
    public class SinglePerson
    {
        public string Name { get; set; }
        public int Age { get; set; }
        private static SinglePerson person = null;

        private SinglePerson() { }

        public static SinglePerson getInstance()
        {
            if (person == null)
                person = new SinglePerson();
            return person;
        }

        public void showName()
        {
            Console.WriteLine("This is my name: " + this.Name);
        }
    }
}
